From a9bf049915552728600996d697ec3b758710ff61 Mon Sep 17 00:00:00 2001 From: Adrian Robert Date: Tue, 24 Feb 2009 12:42:00 +0000 Subject: [PATCH] * nsterm.m (ns_ring_bell): Convert rect to window coordinates before caching. --- src/nsterm.m | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/src/nsterm.m b/src/nsterm.m index b8639834e57..c0b68bfc198 100644 --- a/src/nsterm.m +++ b/src/nsterm.m @@ -844,11 +844,9 @@ ns_ring_bell () r.origin.y += (r.size.height - dim.y) / 2; r.size.width = dim.x; r.size.height = dim.y; - /* XXX: cacheImageInRect under GNUstep does not account for - offset in x_set_window_size, so overestimate (4 fine on Cocoa) */ - surr = NSInsetRect (r, -10, -10); + surr = NSInsetRect (r, -2, -2); ns_focus (frame, &surr, 1); - [[view window] cacheImageInRect: surr]; + [[view window] cacheImageInRect: [view convertRect: surr toView:nil]]; [ns_lookup_indexed_color (NS_FACE_FOREGROUND (FRAME_DEFAULT_FACE (frame)), frame) set]; NSRectFill (r); -- 2.30.2